﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace Ctef.Web.Models
{
    public class HolidayCard
    {
        public string Id { get; set; }
        public string ButtonId { get; set; }
        public string ImageUrl { get; set; }
        public int Width { get; set; }
        public int Height { get; set; }

        public string ItemNumber
        {
            get
            {
                var start = ImageUrl.LastIndexOf('/') + 1;
                var end = ImageUrl.LastIndexOf('.');
                return ImageUrl.Substring(start, end - start);
            }
        }
    }
}